package br.com.biavan.modelo;

public class Celula extends Posicao{
	private String caracter;
	
	public Celula() {

	}
	
	public Celula(String caracter, String coluna, String linha) {
		super(coluna, linha);
		this.caracter = caracter;
	}
	
	public Celula(Celula celula) {
		super(celula);
		this.caracter = celula.getCaracter();
	}
	
	public String getCaracter() {
		return this.caracter;
	}	
	
	public boolean equals(Object object) {
		if (!(object instanceof Celula)) {
			return false;
		}
		Celula outraCelula = (Celula) object;		
		return (outraCelula.getCaracter().equals(this.getCaracter()));
	}
		
	public String toString() {
		return this.caracter;
	}
	
	public String print() {
		return this.caracter + this.getColuna() + this.getLinha();
	}
}
